import React from 'react'
import { FnReload, FnReturn } from '../utils/index'
type Props = {}
//函数重载
function pickCard(age: string): string
function pickCard(age: number): string

function pickCard(age: FnReload): FnReturn {
  if (typeof age === 'string') {
    return age + 'age是string'
  } else if (typeof age === 'number') {
    return age + 'age是number'
  }
}
console.log(pickCard('18'), pickCard(19))

const FunctionReload = (props: Props) => {
  return <div>FunctionReload</div>
}

export default FunctionReload
